using System.Collections.Generic;

namespace LDNS.SDK.Commands.Models
{
    /// <summary>
    /// 删除域名解析记录命令
    /// 用于删除已有的域名解析记录
    /// 作者：huobing
    /// </summary>
    public sealed class RemoveCommand : BaseCommand<DefaultCommandResult>
    {
        public const string NAME = "REMOVE";
        public override string Name => NAME;
        public override string Format => "REMOVE domain";
        public override string Description => "删除域名解析记录";
        public override CommandPermission Permission => CommandPermission.Admin;
        public override IEnumerable<string> Aliases => new[] { "REMOVERECORD", "REMOVE_RECORD" };
        public override bool Validate(string[] args, out string error)
        { 
            error = string.Empty; 
            if (args.Length < 1) { error = "REMOVE 需要一个参数: domain"; return false; } 
            return true; 
        }
    }
}